CREATE TABLE [dbo].[Employee]
(
[Id] [int] NOT NULL,
[Name] [nvarchar] (1024) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[LocationId] [int] NULL,
[Email] [nchar] (1024) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Phone] [nchar] (20) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[EmployeeTypeId] [int] NULL,
[Code] [nchar] (10) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[Status] [int] NULL
) ON [PRIMARY]
ALTER TABLE [dbo].[Employee] ADD
CONSTRAINT [FK_Employee_Location] FOREIGN KEY ([LocationId]) REFERENCES [dbo].[Location] ([Id])
GO
ALTER TABLE [dbo].[Employee] ADD CONSTRAINT [PK_Employee] PRIMARY KEY CLUSTERED  ([Id]) ON [PRIMARY]
GO
ALTER TABLE [dbo].[Employee] ADD CONSTRAINT [FK_Employee_EmployeeType] FOREIGN KEY ([EmployeeTypeId]) REFERENCES [dbo].[EmployeeType] ([Id])
GO
